from django.conf.urls import patterns, include, url
from django.contrib.staticfiles.urls import staticfiles_urlpatterns


urlpatterns = patterns('agile.views', 
   url(r'^$', 'index'),
   url(r'^projects/$', 'projects'),
   url(r'^sprints/$', 'sprints'),
   url(r'^criteria/(?P<cid>\d+)/$', 'tasks'),
   url(r'^tasks/$', 'tasks'),
   url(r'^task/view/(?P<pid>\d+)/$','task_view'),
   url(r'^task/edit/(?P<pid>\d+)/$','task_edit'),
   url(r'^task/delete/(?P<pid>\d+)/$','task_delete'),
   url(r'^task/new/$', 'task_new'), 
   url(r'^project/view/(?P<pid>\d+)/$', 'project_view'),
   url(r'^project/edit/(?P<pid>\d+)/$', 'project_edit'),
   url(r'^project/delete/(?P<pid>\d+)/$', 'project_delete'),
   url(r'^project/confirmdelete/(?P<pid>\d+)/$', 'confirm_project_delete'),   
   url(r'^project/new/$', 'project_new'),
   url(r'^accounts/login/', 'auth'),
   url(r'^logout/', 'logout_view'),
   url(r'^sprint/view/(?P<pid>\d+)/$', 'sprint_view'),
   url(r'^sprint/edit/(?P<pid>\d+)/$', 'sprint_edit'),
   url(r'^sprint/delete/(?P<pid>\d+)/$', 'sprint_delete'),
   url(r'^sprint/confirmdelete/(?P<pid>\d+)/$', 'confirm_sprint_delete'),  
   url(r'^sprint/new/$', 'sprint_new'),
   url(r'^calendar/$', 'calendar'),
   url(r'^comment/post/$', 'comment_post'),                    
   url(r'^comment/edit/(?P<pid>\d+)/$', 'comment_edit'),                    
   url(r'^comment/delete/(?P<pid>\d+)/$', 'comment_delete'),                    
   url(r'^scrums/$', 'scrums'),
   url(r'^scrum/view/(?P<pid>\d+)/$', 'scrum_view'),
   url(r'^scrum/new/$', 'scrum_new'),
   url(r'^scrum/edit/(?P<pid>\d+)/$', 'scrum_edit'),
   url(r'^scrum/delete/(?P<pid>\d+)/$', 'scrum_delete'),
   url(r'^repositorys/$', 'repositorys'),
   url(r'^repository/view/(?P<pid>\d+)/$', 'repository_view'),
   url(r'^repository/edit/(?P<pid>\d+)/$', 'repository_edit'),
   url(r'^repository/delete/(?P<pid>\d+)/$', 'repository_delete'),
   url(r'^repository/new/$', 'repository_new'),
   url(r'^users/$', 'user_view'),
   url(r'^users/password_properties/$', 'user_password_properties'),
   #qurl(r'^users/edit_profile/$', 'user_edit_properties'),
   url(r'^users/edit_profile/(?P<edit>\w{0,10})/$', 'user_edit_properties'),
   url(r'^users/properties_settings_changed/$', 'user_settings_changed'),
  

)

urlpatterns += staticfiles_urlpatterns()

urlpatterns += patterns('',
  (r'^users/change_password/$', 'django.contrib.auth.views.password_change'),
  (r'^users/settings_changed/$', 'django.contrib.auth.views.password_change_done'),
  (r'^users/password_reset/$', 'django.contrib.auth.views.password_reset'),
  (r'^users/password_reset_done/$', 'django.contrib.auth.views.password_reset_done'),
  (r'^reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$', 'django.contrib.auth.views.password_reset_confirm'),
  (r'^reset/done/$', 'django.contrib.auth.views.password_reset_complete'),
  
)
